Skip to content

Deprecate roots, sampling, and logging APIs#1053

Open
arnabnandy7 wants to merge 1 commit into
modelcontextprotocol:mainfrom
arnabnandy7:deprecate/roots-sampling-logging
Open

Deprecate roots, sampling, and logging APIs#1053
arnabnandy7 wants to merge 1 commit into
modelcontextprotocol:mainfrom
arnabnandy7:deprecate/roots-sampling-logging

Conversation

@arnabnandy7

@arnabnandy7 arnabnandy7 commented Jul 2, 2026

Copy link
Copy Markdown

Deprecate Roots, Sampling, and Logging APIs for SEP-2577.

Motivation and Context

Roots, Sampling, and Logging are deprecated in the 2026-07-28 MCP specification release. This change marks the corresponding Java SDK schema types, constants, client APIs, server APIs, and feature configuration surfaces as deprecated while keeping behavior unchanged.

How Has This Been Tested?

  • mvn clean install was run with JDK 21 and Docker/Testcontainers enabled.
  • The build was resumed from :mcp-test after an initial fork interruption.
  • Final result: BUILD SUCCESS; mcp-test completed with 933 tests run, 0 failures, 0 errors, 0 skipped.

Breaking Changes

None. This is a non-breaking deprecation-only change. Existing APIs remain functional but now emit Java deprecation warnings.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update

Checklist

  • I have read the MCP Documentation
  • My code follows the repository's style guidelines
  • New and existing tests pass locally
  • I have added appropriate error handling
  • I have added or updated documentation as needed

Additional context

This change uses standard Java deprecation with @Deprecated and Javadoc @deprecated tags. No runtime behavior was removed or altered.

Resolves #1012

Mark roots, sampling, and logging schema elements, client/server
configuration APIs, and related runtime methods as deprecated for the
2026-07-28 MCP specification update. Keep behavior unchanged while
surfacing standard Java deprecation warnings to downstream consumers.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SEP-2577: Deprecate Roots, Sampling, and Logging

1 participant